public class T12 {
    public static void main(String[] args) {
        int a[]=new int[31];
        int c;
        int max=1;
        for ( c=1;c<=31;c++){
            max*=c;
        }
        System.out.println(max);
        for (int b=1;b<=max;b*=2){
            System.out.println("["+b+"]");
        }

    }

    }

